package com.cn.jiyun.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.cn.jiyun.entity.pojo.Food;
import com.cn.jiyun.entity.pojo.Meals;
import com.cn.jiyun.entity.pojo.Vouchers;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import org.springframework.web.bind.annotation.RequestBody;

import java.util.List;

@Mapper
public interface FoodMapper extends BaseMapper<Food> {
    List<Food> findAllFood();

    List<Food> findFoodOrderByRating(Integer rating);
    @Select("SELECT * FROM food WHERE id = #{id}")
    Food selectById(Integer id);

    List<Food> findFoodByPrice(String price);

    Food getFoodId(Integer foodId);


    List<Vouchers> findVouchers(Vouchers vouchers);

    List<Meals> findMeals(Meals meals);

    Meals findMealById(Integer packageId);
}
